const wxService = {
  login: function (success, fail,complete){
    wx.login({
      success: function (res) { 
        success && success(res)
      },
      fail: function (res) { 
        fail && fail(res)
      },
      complete: function (res) {
        complete && complete(res)
       },
    })
  } ,
  checkSession: function (success, fail, complete){
    wx.checkSession({
      success: function (res) {
        console.log(res)
        success && success(res)
      },
      fail: function (res) {
        fail && fail(res)
      },
      complete: function (res) {
        complete && complete(res)
      },
    })
  }
}

module.exports = wxService


